<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

	<head>
		<meta http-equiv="content-type" content="text/html;charset=utf-8" />
		<meta name="generator" content="Adobe GoLive" />
		<title>Your Website</title>


		<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/jquery-ui.min.js"></script>

		<script type="text/javascript" src="String.js"></script>
		<script type="text/javascript" src="location.js"></script>
		<script type="text/javascript" src="html-parser.js"></script>
		<script type="text/javascript" src="Request.js"></script>

		
		

		<script type="text/javascript">
		
			
		
			var str = "aStirnga";
			console.log(str.trim("a"));
			
			console.log(window.location.setHashParameter("cool", "bro"));
			
			var parser = new HtmlParser("#username what is goin on");
			console.log(parser.linkifyHashTags());
		
		</script>


	</head>

	<body>
	

		Check
		
		
		<form id="form1">
		
		<input name="username" id="username" value="" required>
		<input name="address" value="1 deer lane">
		<p name="FDS">fdss</p>
		<select name="country">
		<option>USA</option>
		<option>UK</option>
		</select>
		
		</form>
		
		
		
	</body>

</html>

<style type="text/css">
.field-error{
	border-color: red;
}
</style>

<script type="text/javascript">


var request = new Request(document.getElementById("form1"));

//request.fields['name'] = {required: true};
//request.addRequired(['name2']);



//request.serializeAssoc("form1");

console.log(request.validate());
alert(request.validate().error);

request.highlightErrors();


//request.postToURL("/action");

</script>